Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add unsafe math optimization error bounds for the non-derived atan2 #1073

Merged
merged 1 commit into from
Oct 15, 2024

Conversation

bashbaug
Copy link
Contributor

@bashbaug bashbaug commented Mar 1, 2024

In the tables describing required accuracy for math functions with "unsafe math optimizations" enabled we describe the required accuracy for both "derived" and "non-derived" implementations for most functions, but not for atan2.

This PR adds the required error bounds for atan2 as <= 8192 ulp, consistent with the required error bounds for the other non-derived implementations.

In addition, for Khronos folks, note that the required error bounds in these cases were originally added by BugZilla 12379. I believe the intent all along was to define non-derived error bounds for atan2, but in the original proposal document the table cell for atan2 wraps onto the next page and it doesn't appear that the non-derived error bounds were ever incorporated into the actual spec.

@bashbaug bashbaug added OpenCL C Spec Issues related to the OpenCL C Language specification. SPIR-V Environment Spec Issues related to the OpenCL SPIR-V Environment specification. labels Mar 1, 2024
@bashbaug bashbaug requested a review from alycm March 1, 2024 06:11
Copy link
Contributor

@alycm alycm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@bashbaug bashbaug merged commit 044deb6 into KhronosGroup:main Oct 15, 2024
2 checks passed
@bashbaug bashbaug deleted the non-derived-relaxed-atan2 branch October 15, 2024 15:00
aharon-abramson pushed a commit to aharon-abramson/OpenCL-Docs that referenced this pull request Feb 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OpenCL C Spec Issues related to the OpenCL C Language specification. SPIR-V Environment Spec Issues related to the OpenCL SPIR-V Environment specification.
Development

Successfully merging this pull request may close these issues.

2 participants